﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Data;
using System.Data.Common;

namespace Db.Paging
{
    internal interface IPager
    {
        /// <summary>
        /// 分页
        /// </summary>
        /// <param name="sql"></param>
        /// <param name="currentPageIndex"></param>
        /// <param name="pageSize"></param>
        /// <param name="hp"></param>
        /// <returns></returns>
        DataTable Paging(string sql, int currentPageIndex, int pageSize, DbHelper hp);

        /// <summary>
        /// 计算总数
        /// </summary>
        /// <param name="sql"></param>
        /// <param name="hp"></param>
        /// <returns></returns>
        int CountPaging(string sql,DbHelper hp);
    }
}
